package acm.蓝桥杯;

import java.io.*;
import java.math.BigInteger;
import java.util.StringTokenizer;

class Reader {
    private StringTokenizer t=new StringTokenizer("");
    private BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
    private PrintWriter pr=new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));

    private String line(){
        try {
            return in.readLine();
        } catch (IOException e) {
            e.printStackTrace();
        }
        return null;
    }
    public boolean hasNext(){
        while (!t.hasMoreElements()){
            String line = line();
            if (line==null) return false;
            t=new StringTokenizer(line);
        }
        return true;
    }
    public String next(){
        hasNext();
        return t.nextToken();
    }
    public String nextLine(){
        t=new StringTokenizer("");
        return line();
    }
    public int nextInt(){
        return Integer.parseInt(next());
    }
    public double nextDouble(){
        return Double.parseDouble(next());
    }
    public long nextLong(){
        return Long.parseLong(next());
    }
    public BigInteger nextBigInteger(){
        return new BigInteger(next());
    }
}
